﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace NetWebControl.ControlTest.OA
{
    public partial class nokey : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            //this.EntityModifyNoKey1.Visible = false;

            Users_Roles role = new Users_Roles();
            this.EntityModifyNoKey1.Entity = role;
            List<ARS.Control.Custom.Entity.Attributes.WhereField> filedList =
                new List<ARS.Control.Custom.Entity.Attributes.WhereField>();
            filedList.Add(new ARS.Control.Custom.Entity.Attributes.WhereField() { FieldName = "ParentId", RequestKey = "pid", IsEncryptKey = true });
            //filedList.Add(new ARS.Control.Custom.Entity.Widget.EntityModifyNoKey.WhereField() { FieldName = "AddTime", Value = "2014-06-06 18:44:06.063" });
            this.EntityModifyNoKey1.WhereFieldList = filedList;
        }

        protected void Button1_Click(object sender, EventArgs e)
        {
            this.EntityModifyNoKey1.AddOrUpdateEntityToDb();
        }
    }
}